import type { RouteRecordRaw } from 'vue-router'
import Layout from '@/views/layout/index.vue'
export const businessRouters: RouteRecordRaw[] = [
  {
    path: '/about',
    name: 'about',
    meta: {
      icon: 'InfoFilled',
      iconType: 'elIcon',
      title: '关于和状态',
    },
    component: Layout,
    redirect: '/about/status',
    children: [
      {
        path: '/about/status',
        name: 'serverStatus',
        component: () => import('@/views/about/status/index.vue'),
        meta: {
          icon: 'Orange',
          iconType: 'elIcon',
          title: '系统状态',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/about/version',
        name: 'serverVersion',
        component: () => import('@/views/about/version/index.vue'),
        meta: {
          icon: 'DataLine',
          iconType: 'elIcon',
          title: '版本信息',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/about/fonts',
        name: 'serverFonts',
        component: () => import('@/views/about/fonts/index.vue'),
        meta: {
          icon: 'Reading',
          iconType: 'elIcon',
          title: '字体',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
    ],
  },
  {
    path: '/geoserver',
    name: 'geoserver',
    meta: {
      icon: 'Collection',
      iconType: 'elIcon',
      title: '服务',
    },
    component: Layout,
    redirect: '/geoserver/workspace',
    children: [
      {
        path: '/geoserver/workspace',
        name: 'serverWorkspace',
        component: () => import('@/views/server/workspace/index.vue'),
        meta: {
          icon: 'Files',
          iconType: 'elIcon',
          title: '工作空间',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/geoserver/datastore',
        name: 'serverDataStore',
        component: () => import('@/views/server/datastore/index.vue'),
        meta: {
          icon: 'Coin',
          iconType: 'elIcon',
          title: '数据存储',
          isLink: '',
          isHide: true,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/geoserver/layers',
        name: 'serverLayers',
        component: () => import('@/views/server/layers/index.vue'),
        meta: {
          icon: 'CopyDocument',
          iconType: 'elIcon',
          title: '图层',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/styles',
        name: 'serverStyles',
        component: () => import('@/views/server/styles/index.vue'),
        meta: {
          icon: 'BrushFilled',
          iconType: 'elIcon',
          title: '样式',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
    ],
  },
  {
    path: '/security',
    name: 'security',
    meta: {
      icon: 'Umbrella',
      iconType: 'elIcon',
      title: '安全',
    },
    component: Layout,
    redirect: '/security/role',
    children: [
      {
        path: '/security/role',
        name: 'serverRoles',
        component: () => import('@/views/security/role/index.vue'),
        meta: {
          icon: 'Postcard',
          iconType: 'elIcon',
          title: '角色管理',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
      {
        path: '/security/user',
        name: 'serverUsers',
        component: () => import('@/views/security/user/index.vue'),
        meta: {
          icon: 'User',
          iconType: 'elIcon',
          title: '用户管理',
          isLink: '',
          isHide: false,
          isFull: false,
          isAffix: false,
          isKeepAlive: true,
        },
      },
    ],
  },
]
